import 'package:library_base/entities/generated/json/base/json_field.dart';
import 'package:library_base/entities/generated/json/task_detail_child_entity.g.dart';
import 'dart:convert';

import 'package:library_base/entities/task_detail_child_child_entity.dart';

@JsonSerializable()
class TaskDetailChildEntity {
  late String goodsCode;
  late String goodsName;
  late String unit;
  late double price;
  late double totalWeight;
  late double serviceCost;
  late double goodsCount;
  late double standardWeight;
  late bool singleEntry;

  late List<TaskDetailChildChildEntity> goodsDetails;

  TaskDetailChildEntity();

  factory TaskDetailChildEntity.fromJson(Map<String, dynamic> json) =>
      $TaskDetailChildEntityFromJson(json);

  Map<String, dynamic> toJson() => $TaskDetailChildEntityToJson(this);

  @override
  String toString() => json.encode(this);
}
